<?php
/**
 * Created by PhpStorm.
 * User: Gooraye
 * Date: 2016-08-09
 * Time: 11:33
 */
namespace Admin\Controller;
use Recruit\Api\UcenterMemberApi;
use Recruit\Api\CompanyApplyApi;
use Recruit\Api\UserResumeApi;
use Recruit\Api\ProjectApi;

class GovController extends AdminController {
    public function index(){
        $this->display();
    }

    /*
     * 查看项目招标应标情况
     * */
    public function look_apply(){
        if(IS_POST){
            $map['title'] = array('like','%'.I('title').'%');
        }
        $map['itboye_project.uid'] = UID;
        $info = apiCall(ProjectApi::QUERY_THREE_JOIN,array($map,'','apply_time desc',$map,'itboye_project.id,itboye_project.title,itboye_project.create_time,itboye_project.come_from,itboye_project_apply.apply_time,itboye_ucenter_member.id as company_id,itboye_ucenter_member.username'));
        if($info['status']){
            $this->assign('list',$info['info']['list']);
            $this->assign('show',$info['info']['show']);
        }
        $this->display();
    }

    /*
     * 查看投标公司简历
     * */
    public function look_resume(){
        $map['uid'] = I('uid');
        $info = apiCall(UserResumeApi::GET_INFO,array($map));
        if($info['status']){
            $info['info']['content'] = htmlspecialchars_decode($info['info']['content']);
            $this->assign($info['info']);
        }
        $this->display();

    }


}